<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<%@ page contentType="text/html;charset=UTF-8" language="java" pageEncoding="UTF-8"%>
<div class="wrapper-xs">
    <div class="panel panel-default">
        <div class="panel-body">
            <%@ include file="/page/common/timeselect.jsp"%>
            <div id="toolbar" class="btn-group">
                <div class="navbar-form " style="margin-top: 0; padding: 0;"
                     role="search">
                    <div class="input-group">
                        <input id="ip_keyWord" type="text" class="form-control" placeholder="search. e.g. *q* or q*.." name="q">
                    </div>
                    <button id="btn-time" type="submit" class="btn btn-default">今天</button>
                    <div class="form-group">
                        <select id="s_redis_count_type" class="selectpicker w-smxl">
                            <option value="100" selected>最近100条</option>
                            <option value="500" >最近500条</option>
                            <option value="1000" >最近1000条</option>
                            <option value="10000" >最近10000条</option>
                        </select>
                    </div>
                    <div class="form-group">
                        <select id="s_redis_sort_type" class="selectpicker w-smxl">
                            <option value="desc" selected>desc by time</option>
                            <option value="asc" >asc by time</option>
                        </select>
                    </div>
                    <button id="btn-query" type="submit" class="btn btn-default">搜索</button>
                    <div class="form-group">
                        <h5 id="id-record">共0条记录</h5>
                    </div>
                </div>
            </div>
            <div id="div-tree" style="float: left;width: 18%;height: 100%">
                <div class="panel panel-default" style="margin-top: 10px">
                    <div class="panel-heading">redis元数据</div>
                    <div class="panel-body" style="overflow-x: auto">
                        <div id="sys_tree">
                        </div>
                    </div>
                </div>
            </div>
            <div style="float: right;width: 80%">
                <table id="id_redis" class="table table-condensed" style="font-size: 6px">
                </table>
            </div>
        </div>
    </div>
</div>
<!-- 预览 Modal -->
<div class="modal fade fade-in-down" id="modal-redis-string" tabindex="-1"
     role="dialog" aria-labelledby="modalLabel" style="margin-top: 150px;">
    <div class="modal-dialog modal-lg" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"
                        aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
                <h4 class="modal-title" >数据查看</h4>
            </div>
            <div class="modal-body">
                <form class=" form-horizontal">
                    <div class="form-group">
                        <label class="col-lg-1 control-label">string：</label>
                        <div class="col-lg-11">
                            <input id="ipt-string" readonly type="text" class="form-control"/>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-lg-1 control-label">value：</label>
                        <div class="col-lg-11">
                            <textarea id="m_tt_b_string" class="form-control" rows=""cols="" ></textarea>
                        </div>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button id="btn-update-redis-string" type="button"  class="btn btn-default">保存</button>
            </div>
        </div>
    </div>
</div>

<!-- 预览 Modal -->
<div class="modal fade fade-in-down" id="modal-redis-list" tabindex="-2"
     role="dialog" aria-labelledby="modalLabel" style="margin-top: 150px;margin-left: 20px">
    <div class="modal-dialog modal-lg" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"
                        aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
                <h4 class="modal-title" >数据查看</h4>
            </div>
            <div class="modal-body" >
                <form class=" form-horizontal">
                    <div class="form-group">
                        <label class="col-lg-1 control-label">list：</label>
                        <div class="col-lg-11">
                            <input id="ipt-list" readonly type="text" class="form-control"/>
                        </div>
                    </div>
                    <div class="form-group">
                        <table id="tb-list" class="table table-condensed " style="font-size: 6px">
                        </table>
                    </div>
                    <div class="form-group">
                        <label class="col-lg-1 control-label">value：</label>
                        <div class="col-lg-11">
                            <textarea id="m_tt_b_list" class="form-control" rows=""cols="" ></textarea>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>

<!-- 预览 Modal -->
<div class="modal fade fade-in-down" id="modal-redis-hash" tabindex="-3"
     role="dialog" aria-labelledby="modalLabel" style="margin-top: 150px;margin-left: 20px">
    <div class="modal-dialog modal-lg" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"
                        aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
                <h4 class="modal-title" >数据查看</h4>
            </div>
            <div class="modal-body" >
                <form class=" form-horizontal">
                    <div class="form-group">
                        <label class="col-lg-1 control-label">hash：</label>
                        <div class="col-lg-11">
                            <input id="ipt-hash" readonly type="text" class="form-control"/>
                        </div>
                    </div>
                    <div class="form-group">
                        <table id="tb-hash" class="table table-condensed" style="font-size: 6px">
                        </table>
                    </div>

                    <div class="form-group">
                        <label class="col-lg-1 control-label">key：</label>
                        <div class="col-lg-11">
                            <input id="ipt-hash-key" type="text" class="form-control"/>
                        </div>
                    </div>

                    <div class="form-group">
                        <label class="col-lg-1 control-label">value：</label>
                        <div class="col-lg-11">
                            <textarea id="m_tt_b_hash" class="form-control" rows=""cols="" ></textarea>
                        </div>
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>

<script src="${ctx}/js/${code}/${code}_${sheet}.js" type="text/javascript" charset="utf-8"></script>